package org.budo.spring.mvc.view.jphp;

import java.io.IOException;
import java.io.OutputStream;

import javax.servlet.ServletOutputStream;
import javax.servlet.WriteListener;

public class BudoServletOutputStream extends ServletOutputStream {
    private OutputStream outputStream;

    public BudoServletOutputStream(OutputStream outputStream) {
        this.outputStream=outputStream;
    }

    @Override
    public boolean isReady() {
        return true;
    }

    @Override
    public void setWriteListener(WriteListener writeListener) {
        throw new RuntimeException("writeListener=" + writeListener);
    }

    @Override
    public void write(int b) throws IOException {
        this.outputStream.write(b);
    }
}